<?php
/**
 *	@name		余额宝
 *	@author		Jeffery
 *	@qq			1017756891
 *	@email		1017756891@qq.com
 *	@website	http://www.iweitao.net
**/
if(!defined('IN_FUND') || !defined('IN_DISCUZ')) {
	exit('Access Denied');
}
class weitao_plugin_fund{
	public function _get($parameter,$number = 0) {
		$parameter = $_GET[$parameter];
		if($number == 1) {
			$parameter = $this->number($parameter);
		} else {
			$parameter = $this->grapheme($parameter);
		}
		return $parameter;
	}
	
	public function _post($parameter,$number = 0 ) {
		$parameter = $_POST[$parameter];
		if($number == 1) {
			$parameter = $this->number($parameter);
		} else {
			$parameter = $this->grapheme($parameter);
		}
		return $parameter;
	}
	
	public function number($number) {
		$number = intval($number);
		return $number;
	}
	
	public function grapheme($parameter) {
		$parameter = addslashes($parameter);
		return $parameter;
	}
	
	public function ungrapheme($parameter) {
		$parameter = stripslashes($parameter);
		return $parameter;
	}
}
?>